﻿<%@ Page Language="C#" MasterPageFile="~/ClientSite.Master" AutoEventWireup="true"
    CodeBehind="DonDatHang.aspx.cs" Inherits="SES.CMS.DonDatHang" Title="Untitled Page" %>

<%@ Register Src="Module/ucLeftMenu.ascx" TagName="ucLeftMenu" TagPrefix="uc2" %>
<%@ Register Src="Module/ucRightMenu.ascx" TagName="ucRightMenu" TagPrefix="uc3" %>
<%@ Register Src="Module/ucBreadcrumb.ascx" TagName="ucBreadcrumb" TagPrefix="uc5" %>
<%@ Register Src="Module/ucHoTro.ascx" TagName="ucHoTro" TagPrefix="uc6" %>
<%@ Register Src="Module/ucShopInfo.ascx" TagName="ucShopInfo" TagPrefix="uc7" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="Style-2-Left">
        <uc7:ucShopInfo ID="ucShopInfo1" runat="server" />
        <uc6:ucHoTro ID="ucHoTro1" runat="server" />
    </div>
    <div class="Style-2-Right">
        <asp:Label ID="lbl" runat="server"></asp:Label>
        <asp:GridView runat="server" ID="GridGioHang" AutoGenerateColumns="False" EmptyDataText="Không có dữ liệu !"
            AllowPaging="True" OnPageIndexChanging="GridGioHang_PageIndexChanging" CellPadding="4"
            Width="679px" BackColor="White" BorderColor="#CC9966" BorderStyle="None" BorderWidth="1px"
            OnRowDataBound="GridGioHang_RowDataBound" DataKeyNames="DonHangID" OnDataBinding="GridGioHang_DataBinding"
            OnDataBound="GridGioHang_DataBound" ShowFooter="false">
            <RowStyle BackColor="White" ForeColor="#330099" />
            <Columns>
                <asp:TemplateField HeaderText="STT">
                    <ItemTemplate>
                        <%# Container.DataItemIndex + 1 %>
                    </ItemTemplate>
                    <ItemStyle HorizontalAlign="Center" />
                </asp:TemplateField>
                <asp:BoundField DataField="TenSanPham" HeaderText="Tên SP" />
                <asp:TemplateField HeaderText="Số Lượng">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="txtSL" Text='<%#DataBinder.Eval(Container.DataItem,"SoLuong") %>'>
                        </asp:Label>
                    </ItemTemplate>
                    <ItemStyle HorizontalAlign="Left" />
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Đơn Giá">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lbDG" Text='<%#DataBinder.Eval(Container.DataItem,"DonGia") %>'>
                        </asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Giảm Giá">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lbGG" Text='<%#DataBinder.Eval(Container.DataItem,"GiamGia") %>'>
                        </asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Thành tiền">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lbTT" Text='<%#DataBinder.Eval(Container.DataItem,"TongTien") %>'>
                        </asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
            </Columns>
            <FooterStyle BackColor="White" ForeColor="#000066" />
            <PagerStyle BackColor="#FFFFCC" ForeColor="#330099" HorizontalAlign="Center" />
            <SelectedRowStyle BackColor="#FFCC66" Font-Bold="True" ForeColor="#663399" />
            <HeaderStyle BackColor="#990000" Font-Bold="True" ForeColor="#FFFFCC" />
        </asp:GridView>
        <br />
        <asp:Label ID="lblSum" runat="server"></asp:Label>
        <div align="center" style="margin-top: 15px;" class="ltr">
            <asp:Label ID="lbThanhtoan" runat="server"></asp:Label>
        </div>
        <br />
        <div align="center" style="margin-top: 15px;" class="ltr dGioHang">
            <a href="/Default.aspx" class="continue_link">Trở về trang chủ</a>
            <div style="margin-top: 40px;">
                <hr />
                <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                    <ContentTemplate>
                        <div class="SP">
                            Sản phẩm bán chạy
                            <ul class="sanPham">
                                <asp:Repeater runat="server" ID="rpt">
                                    <ItemTemplate>
                                        <li><a href='/SanPhamChiTiet/<%#Eval("SanPhamID")%>/<%#FriendlyUrl(Eval("TenSanPham").ToString())%>'>
                                            <img src='/Media/<%#Eval("HinhAnh")%>' title='<%#Eval("TenSanPham")%>' alt='<%#Eval("TenSanPham")%>'
                                                class="bear" />
                                            <p class="pSanPham">
                                                <span class="spanTenSanPham">
                                                    <%#Eval("TenSanPham")%>
                                                </span>
                                            </p>
                                            <p class="pSanPham">
                                                <span class="spanDonGia">
                                                    <%#(bool)(Int64.Parse(Eval("DonGia").ToString()) == 0) ? "Liên hệ" : Eval("DonGia", "{0:0,0} đ")%>
                                                </span>
                                            </p>
                                        </a></li>
                                    </ItemTemplate>
                                </asp:Repeater>
                            </ul>
                            <asp:Label runat="server" Text="" ID="lbThongbao"></asp:Label>
                        </div>
                        <div style="width: 100%; float: left; margin-top: 10px;">
                            <div style="float: left;">
                                <asp:ImageButton ID="cmdPrev" Visible="false" OnClick="cmdPrev_Click" runat="server"
                                    ImageUrl="~/images/prevpage.png" /></div>
                            <div style="float: right;">
                                <asp:ImageButton ID="cmdNext" Visible="false" OnClick="cmdNext_Click" runat="server"
                                    ImageUrl="~/images/nextpage.png" /></div>
                        </div>
                    </ContentTemplate>
                </asp:UpdatePanel>
            </div>
        </div>
    </div>
</asp:Content>
